package com.example.controller;


import com.example.config.R;
import com.example.service.IMemberService;
import io.swagger.annotations.Api;
import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 会员Controller
 *
 * @author ruoyi
 * @date 2022-11-22
 */

@RestController
@RequestMapping("/system/member")
public class MemberController  {

    @Autowired
    private IMemberService iMemberService;

    /**
     * 获取会员信息
     * @param dealerId
     * @return
     */
    @GetMapping("getMember")
    public R getMember(Long dealerId)
    {
        if(dealerId==null)
        {
            return R.fail("参数错误");
        }
        return iMemberService.getMember(dealerId);
    }

}
